﻿using System;

namespace SPFluid.Core.Validation.Extensions
{
    public static class GuidValidatorExtensions
    {
        public static IGuard<Guid> IsNotEmpty(this IGuard<Guid> guard)
        {
            if (Guid.Empty.Equals(guard.Argument.Value))
            {
                guard.ExceptionHandler.ThrowArgumentException("Guid is empty");
            }

            return guard;
        } 
    }
}